-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[18.0][MIG] web_widget_bokeh_chart #3076
base: 18.0
Are you sure you want to change the base?
[18.0][MIG] web_widget_bokeh_chart #3076
Conversation
Avoid "Duplicate explicit target name" error using anonymous hyperlink references Ref.: https://stackoverflow.com/questions/5464627/how-to-have-same-text-in-two-links-with-restructured-text/14067756#14067756
…ontainer element.
…mit dynamic updates
Includes some manual fixes to silent ESLint warnings.
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate. Translation: web-16.0/web-16.0-web_widget_bokeh_chart Translate-URL: https://translation.odoo-community.org/projects/web-16-0/web-16-0-web_widget_bokeh_chart/
Co-authored-by: Enric Tobella [email protected] Co-authored-by: David Jimenez [email protected]
Update bokeh from 3.1.1 to 3.4.1
When debug mode is enabled, the console shows this error:
|
@@ -0,0 +1,52 @@ | |||
/* global document */ | |||
import {markup, onMounted, onPatched, onWillStart, useRef} from "@odoo/owl"; | |||
import {CharField} from "@web/views/fields/char/char_field"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add charField import and change export to:
export const bokehChartWidget = {
...charField,
component: BokehChartWidget,
};
To fix the console error when debug mode is enabled
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated, Thanks
}); | ||
super.setup(); | ||
onWillStart(() => | ||
loadBundle({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
since 18.0 loadBundle function only permit string arguments. Try to call loadJS function for every path inside a function.
export async function loadBokehLibraries() {
const scripts = [
"/web_widget_bokeh_chart/static/src/lib/bokeh/bokeh-3.4.1.min.js",
"/web_widget_bokeh_chart/static/src/lib/bokeh/bokeh-api-3.4.1.min.js",
"/web_widget_bokeh_chart/static/src/lib/bokeh/bokeh-widgets-3.4.1.min.js",
"/web_widget_bokeh_chart/static/src/lib/bokeh/bokeh-tables-3.4.1.min.js",
"/web_widget_bokeh_chart/static/src/lib/bokeh/bokeh-mathjax-3.4.1.min.js",
"/web_widget_bokeh_chart/static/src/lib/bokeh/bokeh-gl-3.4.1.min.js",
];
for (const script of scripts) {
await loadJS(script);
}
}
And then call it inside onWillStart:
onWillStart(() => loadBokehLibraries());
By this way, the function could be called from other modules.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated, Thanks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please apply the same logic to web_widget_bokeh_json_chart.esm.js file
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
7720806
to
94be57c
Compare
94be57c
to
1b75d2b
Compare
Standard Migration
@ForgeFlow